package com.hr.domain.vo;

import lombok.Data;

/**
 * 房源配套设施表
 * @TableName house_facility
 */
@Data
public class HouseFacilityVO {
    /**
     * 
     */
    private Long id;

    /**
     * 房源ID
     */
    private Long houseId;

    /**
     * 配套类型(交通/商圈/医院)
     */
    private String facilityType;

    /**
     * 配套名称
     */
    private String name;

    /**
     * 距离房源距离
     */
    private String distance;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        HouseFacilityVO other = (HouseFacilityVO) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getHouseId() == null ? other.getHouseId() == null : this.getHouseId().equals(other.getHouseId()))
            && (this.getFacilityType() == null ? other.getFacilityType() == null : this.getFacilityType().equals(other.getFacilityType()))
            && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
            && (this.getDistance() == null ? other.getDistance() == null : this.getDistance().equals(other.getDistance()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getHouseId() == null) ? 0 : getHouseId().hashCode());
        result = prime * result + ((getFacilityType() == null) ? 0 : getFacilityType().hashCode());
        result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
        result = prime * result + ((getDistance() == null) ? 0 : getDistance().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", houseId=").append(houseId);
        sb.append(", facilityType=").append(facilityType);
        sb.append(", name=").append(name);
        sb.append(", distance=").append(distance);
        sb.append("]");
        return sb.toString();
    }
}